import Mock from 'mockjs2'
import { getRandomDateBetween } from '@/utils/util'

Mock.Random.extend({
  lastDate: function () {
    return getRandomDateBetween('yyyy-MM-dd')
  }
})

Mock.Random.extend({
  lastDateTime: function () {
    return getRandomDateBetween('yyyy-MM-dd HH:mm:ss')
  }
})

// 考试图片相关
const imgType = ['image/jpg', 'image/jpeg', 'image/png', 'image/gif']
const maxImgSize = 1024 * 1024 * 5
const imagesServerPrefix = 'http://47.99.194.179:8888/'

export default {
  imgType,
  maxImgSize,
  imagesServerPrefix
}
